package org.s45.erp.api;

import com.ttxs.common.core.vo.R;
import org.s45.erp.api.params.LoginResult;
import org.s45.erp.api.params.UserParam;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient(contextId = "RemoteAuthService",
        name = "jshERP-boot",
        path = "/jshERP-boot/user")
public interface RemoteAuthService {

    @PostMapping(value = "/login")
    R<LoginResult>login(@RequestBody UserParam userParam);

    @GetMapping(value = "/logout")
    R logout();

    @PostMapping(value = "/registerUser")
    R registerUser(@RequestBody UserParam userParam);
}
